<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@include file="header.jsp"%>

<jsp:useBean id="user" class="entities.User" scope="session"/>
<% if (user.getUser() != null) {%>
Vous ne pouvez pas acceder à cette page
<%} else {%>


<jsp:useBean id="error" class="java.lang.String" scope="request"/>
<jsp:useBean id="nameUser" class="java.lang.String" scope="request"/>
<jsp:useBean id="surnameUser" class="java.lang.String" scope="request"/>
<jsp:useBean id="mailUser" class="java.lang.String" scope="request"/>
<jsp:useBean id="ageUser" class="java.lang.String" scope="request"/>
<jsp:useBean id="idUser" class="java.lang.String" scope="request"/>
<jsp:useBean id="message" class="java.lang.String" scope="request"/>


<h1>INSCRIPTIONS</h1>

<% if (!message.isEmpty()) { %>
    <p class="informations">Informations :</p>
    <ul class="informations"><li><%= message %></li></ul>
<% } %>

<p>
    L'inscription sur notre site est gratuite. Elle vous permettra de lancer vos propres évènements !
    <br/>


</p>

<h2 style="margin-bottom:0px;">Je veux m'enregistrer</h2>

<% if (!error.equals(null) && !error.isEmpty()) {%>
<p style="color:red; font-weight:bold;">Il y a des erreurs :</p>
<ul>
    <%=error%>
</ul>
<%}%>



<div id="formulaire">
    <form action="AddUser2" id="addUser" name="addUser" method="post" style="margin-top:-5px;">

        <fieldset id="informations_personelles">
            <h3>Vos informations personelles</h3>
            <p><label for="nameUser">Nom</label>
                <input name="nameUser" type="text" id="nameUser" value="<% out.print(nameUser);%>" />
            <span id="infonameUser" class="info"></span></p>
            <p><label for="surnameUser">Pr&eacute;nom</label>
                <input  name="surnameUser" type="text" id="surnameUser" value="<% out.print(surnameUser);%>" />

            <span id="infosurnameUser" class="info"></span></p>
    <p><label for="sexUser">Sexe</label>
    <input type="radio"  name=sexUser value="Man"  checked>Man<br/>
 	<input type="radio"  name=sexUser value="Women" >Women</span></p>
 	
 	<p><label for="ageUser">Age</label>
 	<input type="text" name="ageUser" id="ageUser" value="<% out.print(ageUser);%>">
    <span id="infoageUser" class="info"></span></p>

        </fieldset>


        <fieldset id="contacts">
            <h3>Vous contacter</h3>
            <p><label for="mailUser">Mail</label>
             <input name="mailUser" type="text" id="mailUser" value="<% out.print(mailUser);%>" />
            <span id="infomailUser" class="info"></span></p>
            
        </fieldset>

        <fieldset id="identifiants">

            <h3>Vos identifiants</h3>
            <p>
                <label for="idUser">Login</label>
                <input name="idUser"  id="idUser" value="<% out.print(idUser);%>" />
            <span id="infoidUser" class="info"></span></p>
            <p><label for="passUser">Mot de passe</label>
                <input  name="passUser" type="password" id="passUser" value="" />
            <span id="infopassUser" class="info"></span></p>

        </fieldset>


        <fieldset id="enregistrement">
            <h3>Vous enregistrer</h3>
            <p><input id="button" name="Soumettre" type="submit" value="Soumettre"/></p>
        </fieldset>



    </form>
</div>
<%}%>
    </div>


</body>
</html>